﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using Lidgren.Network;

namespace Network.Messages.FileTranser
{
    public class NotifyNewTextCanPasteMessage : NovaMessage
    {

        public NotifyNewTextCanPasteMessage() : base((ushort)CustomMessageType.NotifyNewTextCanPasteMessage)
        {
        }

        /// <summary>
        /// 被复制的文本
        /// </summary>
        public string Text;

        public override void WritePayload(NetOutgoingMessage message)
        {
            base.WritePayload(message);
            message.Write(Text);
        }

        public override void ReadPayload(NetIncomingMessage message)
        {
            base.ReadPayload(message);
            Text = message.ReadString();
        }
    }
}
